Optimal. Leaf size=73 \[ \frac {i (e+f x)^2}{2 a f}-\frac {2 i (e+f x) \log \left (1+i e^{c+d x}\right )}{a d}-\frac {2 i f \text {PolyLog}\left (2,-i e^{c+d x}\right )}{a d^2} \]
[Out]
________________________________________________________________________________________
Rubi [A]
time = 0.08, antiderivative size = 73, normalized size of antiderivative = 1.00, number of steps
used = 4, number of rules used = 4, integrand size = 27, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.148, Rules used = {5678, 2221,
2317, 2438} \begin {gather*} -\frac {2 i f \text {Li}_2\left (-i e^{c+d x}\right )}{a d^2}-\frac {2 i (e+f x) \log \left (1+i e^{c+d x}\right )}{a d}+\frac {i (e+f x)^2}{2 a f} \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
Rule 2221
Rule 2317
Rule 2438
Rule 5678
Rubi steps
\begin {align*} \int \frac {(e+f x) \cosh (c+d x)}{a+i a \sinh (c+d x)} \, dx &=\frac {i (e+f x)^2}{2 a f}+2 \int \frac {e^{c+d x} (e+f x)}{a+i a e^{c+d x}} \, dx\\ &=\frac {i (e+f x)^2}{2 a f}-\frac {2 i (e+f x) \log \left (1+i e^{c+d x}\right )}{a d}+\frac {(2 i f) \int \log \left (1+i e^{c+d x}\right ) \, dx}{a d}\\ &=\frac {i (e+f x)^2}{2 a f}-\frac {2 i (e+f x) \log \left (1+i e^{c+d x}\right )}{a d}+\frac {(2 i f) \text {Subst}\left (\int \frac {\log (1+i x)}{x} \, dx,x,e^{c+d x}\right )}{a d^2}\\ &=\frac {i (e+f x)^2}{2 a f}-\frac {2 i (e+f x) \log \left (1+i e^{c+d x}\right )}{a d}-\frac {2 i f \text {Li}_2\left (-i e^{c+d x}\right )}{a d^2}\\ \end {align*}
________________________________________________________________________________________
Mathematica [A]
time = 0.02, size = 66, normalized size = 0.90 \begin {gather*} \frac {i \left (d (e+f x) \left (d (e+f x)-4 f \log \left (1+i e^{c+d x}\right )\right )-4 f^2 \text {PolyLog}\left (2,-i e^{c+d x}\right )\right )}{2 a d^2 f} \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
Maple [B] Both result and optimal contain complex but leaf count of result is larger than twice
the leaf count of optimal. 187 vs. \(2 (64 ) = 128\).
time = 1.52, size = 188, normalized size = 2.58
method | result | size |
risch | \(\frac {i f \,x^{2}}{2 a}-\frac {i e x}{a}-\frac {2 i \ln \left ({\mathrm e}^{d x +c}-i\right ) e}{d a}+\frac {2 i \ln \left ({\mathrm e}^{d x +c}\right ) e}{d a}+\frac {2 i f c x}{d a}+\frac {i f \,c^{2}}{d^{2} a}-\frac {2 i f \ln \left (1+i {\mathrm e}^{d x +c}\right ) x}{d a}-\frac {2 i f \ln \left (1+i {\mathrm e}^{d x +c}\right ) c}{d^{2} a}-\frac {2 i f \polylog \left (2, -i {\mathrm e}^{d x +c}\right )}{a \,d^{2}}+\frac {2 i f c \ln \left ({\mathrm e}^{d x +c}-i\right )}{d^{2} a}-\frac {2 i f c \ln \left ({\mathrm e}^{d x +c}\right )}{d^{2} a}\) | \(188\) |
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Maxima [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {Failed to integrate} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Fricas [A]
time = 0.35, size = 95, normalized size = 1.30 \begin {gather*} \frac {i \, d^{2} f x^{2} - 2 i \, c^{2} f - 4 i \, f {\rm Li}_2\left (-i \, e^{\left (d x + c\right )}\right ) - 2 \, {\left (-i \, d^{2} x - 2 i \, c d\right )} e - 4 \, {\left (-i \, c f + i \, d e\right )} \log \left (e^{\left (d x + c\right )} - i\right ) - 4 \, {\left (i \, d f x + i \, c f\right )} \log \left (i \, e^{\left (d x + c\right )} + 1\right )}{2 \, a d^{2}} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Sympy [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} - \frac {i \left (\int \frac {e \cosh {\left (c + d x \right )}}{\sinh {\left (c + d x \right )} - i}\, dx + \int \frac {f x \cosh {\left (c + d x \right )}}{\sinh {\left (c + d x \right )} - i}\, dx\right )}{a} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Giac [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {could not integrate} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Mupad [F]
time = 0.00, size = -1, normalized size = -0.01 \begin {gather*} \int \frac {\mathrm {cosh}\left (c+d\,x\right )\,\left (e+f\,x\right )}{a+a\,\mathrm {sinh}\left (c+d\,x\right )\,1{}\mathrm {i}} \,d x \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________